<!DOCTYPE html>
<html lang="en" xmlns:th="http://www.thymeleaf.org">

<head>
    <meta charset="UTF-8">
    <title>订单详情</title>
    <style>
        table {
            width: 80%;
            margin: 20px auto;
            border-collapse: collapse;
            font-family: Arial, sans-serif; /* 字体 */
        }

        th, td {
            border-bottom: 1px solid #ddd;
            border-left: 1px solid #ddd;
            border-right: 1px solid #ddd;
            padding: 10px;
            text-align: center; /* 中央对齐 */
        }
        td {
            color: #555;
        }
    </style>
</head>
<body>
<div th:replace="head"></div>
<div class="page-header">
    <div class="container">
        <div class="row">
            <div class="col-lg-12 col-md-12 col-sm-12 col-xs-12">
                <div class="page-caption">
                    <h2 class="page-title">订单详情</h2>
                    <p>Healthy & delicious cuisine</p>
                </div>
            </div>
        </div>
    </div>
</div>
    <table>

        <tr>
            <th>菜品图片</th>
            <th>菜品名称</th>
            <th>菜品价格</th>
        </tr>
        <tr th:each="d:${dishesList}">
            <td width="300"><img th:src="${d.img}" height="180" width="320"></td>
            <td th:text="${d.name}" width="400"></td>
            <td th:text="${d.price}" width="300"></td>
        </tr>
        <tr>
            <td><h3>订单状态</h3></td>
            <td th:switch="${order.order_status}">
                <label th:case="0">未完成</label>
                <label th:case="1">已支付</label>
                <label th:case="2">已取消</label>
            </td>
        </tr>
        <tr th:if="${order.order_status}==0">
            <td><h3>操作</h3></td>
            <td><a th:href="@{'/order/cancle/'+${order.order_id}}">取消</a>
            |<a th:href="@{'/order/pay/'+${order.order_id}}">支付</a>
            </td>
        </tr>
    </table>

<a th:href="@{/order/showorder}">返回</a>
<div th:replace="footer"></div>
</body>
</html>